import pygame

# 颜色常量
BACKGROUND_COLOR = (210, 180, 140)  # 深土黄色
PLAYER_COLOR = (0, 100, 0)  # 墨绿色
ENEMY_COLOR = (0, 0, 139)  # 深蓝色
BULLET_COLOR = (255, 69, 0)  # 火焰色

# 窗口常量
WINDOW_WIDTH = 1200
WINDOW_HEIGHT = 860

# 坦克常量
TANK_WIDTH = 30
TANK_HEIGHT = 40
TANK_CORNER_RADIUS = 5
TURRET_RADIUS = 13
CANNON_LENGTH = 45

# 炮弹常量
BULLET_RADIUS = 2
BULLET_SPEED = 260
BULLET_MAX_RANGE = 550

# 坦克速度常量
PLAYER_SPEED = 100
ENEMY_SPEED = PLAYER_SPEED * 0.5

# 坦克初始角度
PLAYER_INITIAL_ANGLE = 0
ENEMY_INITIAL_ANGLE_MIN = 100
ENEMY_INITIAL_ANGLE_MAX = 260

# 坦克生命值和炮弹数量
INITIAL_HEALTH = 100
INITIAL_AMMO = 100

# 炮弹发射速度
PLAYER_FIRE_RATE = 2  # 每秒
ENEMY_FIRE_RATE = 1  # 每秒

# 坦克移动和旋转常量
TANK_MOVE_DISTANCE = 6
TANK_ROTATION_ANGLE = 2
TANK_MAX_ROTATION_SPEED = 60  # 度/秒
CANNON_ROTATION_ANGLE = 3
CANNON_MAX_ROTATION_SPEED = 180  # 度/秒

# 游戏时间
GAME_DURATION = 120  # 秒

# 字体大小
RESULT_FONT_SIZE = 50
STATS_FONT_SIZE = 20

# AI常量
AI_SAFE_DISTANCE = 400

# 键盘按键
KEY_UP = pygame.K_UP
KEY_DOWN = pygame.K_DOWN
KEY_LEFT = pygame.K_LEFT
KEY_RIGHT = pygame.K_RIGHT
KEY_FIRE = pygame.K_SPACE
KEY_CANNON_LEFT = pygame.K_a
KEY_CANNON_RIGHT = pygame.K_d